import http from "@/utils/http";
// 获取已登录用户的地址信息
export const getMemberAddress = () => {
    return http({
        url: '/member/address'
    })
}

// 新增地址
export const postMemberAddress = (data) => {
    return http({
        url: '/member/address',
        method: 'post',
        data
    })
}

// 删除地址
export const deleteMemberAddress = (id) => {
    return http({
        url: '/member/address/' + id,
        method: 'delete'
    })
}

// 获取当个详情信息
export const getDateilMemberAddress = (id) => {
    return http({
        url: '/member/address/' + id
    })
}

// 编辑信息
export const putMemberAddress = (id, data) => {
    return http({
        url: '/member/address/' + id,
        method: 'put',
        data
    })
}
